##########################################
## Copyright 2012-2013 Ceruti Francesco & contributors
##
## This file is part of LiSP (Linux Show Player).
##########################################

from PyQt4 import QtGui, QtCore


class About(QtGui.QDialog):

    TEXT = '''
        <center>
            <b style="font-size: 16pt">LiSP (Linux Show Player)</b><br />
            <br />
            <b>Copyright (C) 2012-2013</b><br />
            Ceruti Francesco <a href="mailto:ceppofrancy@gmail.com">ceppofrancy@gmail.com</a><br />
            <br />
            <b>Contributors</b><br />
            Marco Asa<br/>
            <br />
            LiSP (Linux Show Player) is free software: you can redistribute it and/or modify
            it under the terms of the GNU Lesser General Public License as published by
            the Free Software Foundation, either version 3 of the License, or
            (at your option) any later version.
            <br /><br />
            LiSP (Linux Show Player) is distributed in the hope that it will be useful,
            but WITHOUT ANY WARRANTY; without even the implied warranty of
            MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
            GNU Lesser General Public License for more details.
        </center>'''

    def __init__(self, parent=None):
        super(About, self).__init__(parent)

        self.setWindowModality(QtCore.Qt.ApplicationModal)
        self.setWindowTitle('About LiSP (Linux Show Player)')
        self.setMaximumSize(500, 410)
        self.setMinimumSize(500, 410)
        self.resize(500, 410)

        self.about = QtGui.QTextBrowser(self)
        self.about.setGeometry(QtCore.QRect(0, 0, 500, 410))
        self.about.setHtml(About.TEXT)

        self.ok = QtGui.QPushButton('O&k', self.about)
        self.ok.move(460, 370)
        self.ok.clicked.connect(self.close)
